{%extends 'show/iframe_base.html'%}

{%block content%}
<pre id="editor" >{{content|safe}}</pre>
<script src="https://cdn.staticfile.org/ace/1.4.2/ace.js"></script>
<script src="https://cdn.staticfile.org/ace/1.4.2/ext-language_tools.js"></script>
<script>
    var editor = ace.edit("editor");
    editor.setTheme("ace/theme/ambiance");
    editor.setFontSize(18);
    editor.session.setMode("ace/mode/{{language}}");

    //Autocompletion
    editor.setOptions({
        enableBasicAutocompletion: true,
        enableSnippets: true,
        enableLiveAutocompletion: true,
        maxLines: Infinity
    });
</script>
{%endblock content%}
